package com.lam.dormitory.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 *
 * </p>
 *
 * @author lam
 * @since 2019-12-26
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value = "Repair对象", description = "")
public class Repair implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "报修id")
    @TableId(value = "repair_id", type = IdType.INPUT)
    private Long repairId;

    @ApiModelProperty(value = "宿舍id")
    private Long dorId;

    @ApiModelProperty(value = "报修种类 1物资损坏 2网络故障")
    private Integer repairKind;

    @ApiModelProperty(value = "报修原因")
    private String repairReason;

    @ApiModelProperty(value = "报修提交日期")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date submitDate;

    @ApiModelProperty(value = "报修解决日期")
    @DateTimeFormat(pattern="yyyy-MM-dd")
    private Date resolvedDate;

    @ApiModelProperty(value = "报修状态：0已删除; 1未删除")
    @TableLogic
    private Integer status;

}
